package com.xydtech.rule.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.xydtech.rule.mapper.RuleElementsGroupDetailMapper;
import com.xydtech.rule.domain.RuleElementsGroupDetail;
import com.xydtech.rule.service.IRuleElementsGroupDetailService;
import com.xydtech.common.core.text.Convert;

/**
 * 规则组明细Service业务层处理
 * 
 * @author xydtech
 * @date 2024-06-07
 */
@Service
public class RuleElementsGroupDetailServiceImpl implements IRuleElementsGroupDetailService 
{
    @Autowired
    private RuleElementsGroupDetailMapper ruleElementsGroupDetailMapper;

    /**
     * 查询规则组明细
     * 
     * @param id 规则组明细主键
     * @return 规则组明细
     */
    @Override
    public RuleElementsGroupDetail selectRuleElementsGroupDetailById(Long id)
    {
        return ruleElementsGroupDetailMapper.selectRuleElementsGroupDetailById(id);
    }

    /**
     * 查询规则组明细列表
     *
     * @param ruleElementsGroupDetail 规则组明细
     * @return 规则组明细
     */
    @Override
    public List<RuleElementsGroupDetail> selectRuleElementsGroupDetailList(RuleElementsGroupDetail ruleElementsGroupDetail)
    {
        return ruleElementsGroupDetailMapper.selectRuleElementsGroupDetailList(ruleElementsGroupDetail);
    }

    @Override
    public int batchInsertRuleElementsGroupDetail(List<RuleElementsGroupDetail> groupDetailList) {
        return ruleElementsGroupDetailMapper.batchInsertRuleElementsGroupDetail(groupDetailList);
    }

    /**
     * 新增规则组明细
     * 
     * @param ruleElementsGroupDetail 规则组明细
     * @return 结果
     */
    @Override
    public int insertRuleElementsGroupDetail(RuleElementsGroupDetail ruleElementsGroupDetail)
    {
        return ruleElementsGroupDetailMapper.insertRuleElementsGroupDetail(ruleElementsGroupDetail);
    }

    /**
     * 修改规则组明细
     * 
     * @param ruleElementsGroupDetail 规则组明细
     * @return 结果
     */
    @Override
    public int updateRuleElementsGroupDetail(RuleElementsGroupDetail ruleElementsGroupDetail)
    {
        return ruleElementsGroupDetailMapper.updateRuleElementsGroupDetail(ruleElementsGroupDetail);
    }

    /**
     * 批量删除规则组明细
     * 
     * @param ids 需要删除的规则组明细主键
     * @return 结果
     */
    @Override
    public int deleteRuleElementsGroupDetailByIds(String ids)
    {
        return ruleElementsGroupDetailMapper.deleteRuleElementsGroupDetailByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除规则组明细信息
     * 
     * @param id 规则组明细主键
     * @return 结果
     */
    @Override
    public int deleteRuleElementsGroupDetailById(Long id)
    {
        return ruleElementsGroupDetailMapper.deleteRuleElementsGroupDetailById(id);
    }
}
